3.147 \(\int \frac {\sqrt {a+a \cos (c+d x)}}{x} \, dx\)

Optimal. Leaf size=84 \[ \cos \left (\frac {c}{2}\right ) \text {Ci}\left (\frac {d x}{2}\right ) \sec \left (\frac {c}{2}+\frac {d x}{2}\right ) \sqrt {a \cos (c+d x)+a}-\sin \left (\frac {c}{2}\right ) \text {Si}\left (\frac {d x}{2}\right ) \sec \left (\frac {c}{2}+\frac {d x}{2}\right ) \sqrt {a \cos (c+d x)+a} \]

[Out]

Ci(1/2*d*x)*cos(1/2*c)*sec(1/2*d*x+1/2*c)*(a+a*cos(d*x+c))^(1/2)-sec(1/2*d*x+1/2*c)*Si(1/2*d*x)*sin(1/2*c)*(a+
a*cos(d*x+c))^(1/2)

________________________________________________________________________________________

Rubi [A]  time = 0.12, antiderivative size = 84, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 18, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.222, Rules used = {3319, 3303, 3299, 3302} \[ \cos \left (\frac {c}{2}\right ) \text {CosIntegral}\left (\frac {d x}{2}\right ) \sec \left (\frac {c}{2}+\frac {d x}{2}\right ) \sqrt {a \cos (c+d x)+a}-\sin \left (\frac {c}{2}\right ) \text {Si}\left (\frac {d x}{2}\right ) \sec \left (\frac {c}{2}+\frac {d x}{2}\right ) \sqrt {a \cos (c+d x)+a} \]

Antiderivative was successfully verified.

[In]

Int[Sqrt[a + a*Cos[c + d*x]]/x,x]

[Out]

Cos[c/2]*Sqrt[a + a*Cos[c + d*x]]*CosIntegral[(d*x)/2]*Sec[c/2 + (d*x)/2] - Sqrt[a + a*Cos[c + d*x]]*Sec[c/2 +
 (d*x)/2]*Sin[c/2]*SinIntegral[(d*x)/2]

Rule 3299

Int[sin[(e_.) + (f_.)*(x_)]/((c_.) + (d_.)*(x_)), x_Symbol] :> Simp[SinIntegral[e + f*x]/d, x] /; FreeQ[{c, d,
 e, f}, x] && EqQ[d*e - c*f, 0]

Rule 3302

Int[sin[(e_.) + (f_.)*(x_)]/((c_.) + (d_.)*(x_)), x_Symbol] :> Simp[CosIntegral[e - Pi/2 + f*x]/d, x] /; FreeQ
[{c, d, e, f}, x] && EqQ[d*(e - Pi/2) - c*f, 0]

Rule 3303

Int[sin[(e_.) + (f_.)*(x_)]/((c_.) + (d_.)*(x_)), x_Symbol] :> Dist[Cos[(d*e - c*f)/d], Int[Sin[(c*f)/d + f*x]
/(c + d*x), x], x] + Dist[Sin[(d*e - c*f)/d], Int[Cos[(c*f)/d + f*x]/(c + d*x), x], x] /; FreeQ[{c, d, e, f},
x] && NeQ[d*e - c*f, 0]

Rule 3319

Int[((c_.) + (d_.)*(x_))^(m_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Dist[((2*a)^IntPart[n
]*(a + b*Sin[e + f*x])^FracPart[n])/Sin[e/2 + (a*Pi)/(4*b) + (f*x)/2]^(2*FracPart[n]), Int[(c + d*x)^m*Sin[e/2
 + (a*Pi)/(4*b) + (f*x)/2]^(2*n), x], x] /; FreeQ[{a, b, c, d, e, f, m}, x] && EqQ[a^2 - b^2, 0] && IntegerQ[n
 + 1/2] && (GtQ[n, 0] || IGtQ[m, 0])

Rubi steps

\begin {align*} \int \frac {\sqrt {a+a \cos (c+d x)}}{x} \, dx &=\left (\sqrt {a+a \cos (c+d x)} \csc \left (\frac {1}{2} \left (c+\frac {\pi }{2}\right )+\frac {\pi }{4}+\frac {d x}{2}\right )\right ) \int \frac {\sin \left (\frac {1}{2} \left (c+\frac {\pi }{2}\right )+\frac {\pi }{4}+\frac {d x}{2}\right )}{x} \, dx\\ &=\left (\cos \left (\frac {c}{2}\right ) \sqrt {a+a \cos (c+d x)} \csc \left (\frac {1}{2} \left (c+\frac {\pi }{2}\right )+\frac {\pi }{4}+\frac {d x}{2}\right )\right ) \int \frac {\cos \left (\frac {d x}{2}\right )}{x} \, dx-\left (\sqrt {a+a \cos (c+d x)} \csc \left (\frac {1}{2} \left (c+\frac {\pi }{2}\right )+\frac {\pi }{4}+\frac {d x}{2}\right ) \sin \left (\frac {c}{2}\right )\right ) \int \frac {\sin \left (\frac {d x}{2}\right )}{x} \, dx\\ &=\cos \left (\frac {c}{2}\right ) \sqrt {a+a \cos (c+d x)} \text {Ci}\left (\frac {d x}{2}\right ) \sec \left (\frac {c}{2}+\frac {d x}{2}\right )-\sqrt {a+a \cos (c+d x)} \sec \left (\frac {c}{2}+\frac {d x}{2}\right ) \sin \left (\frac {c}{2}\right ) \text {Si}\left (\frac {d x}{2}\right )\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.09, size = 55, normalized size = 0.65 \[ \sec \left (\frac {1}{2} (c+d x)\right ) \sqrt {a (\cos (c+d x)+1)} \left (\cos \left (\frac {c}{2}\right ) \text {Ci}\left (\frac {d x}{2}\right )-\sin \left (\frac {c}{2}\right ) \text {Si}\left (\frac {d x}{2}\right )\right ) \]

Antiderivative was successfully verified.

[In]

Integrate[Sqrt[a + a*Cos[c + d*x]]/x,x]

[Out]

Sqrt[a*(1 + Cos[c + d*x])]*Sec[(c + d*x)/2]*(Cos[c/2]*CosIntegral[(d*x)/2] - Sin[c/2]*SinIntegral[(d*x)/2])

________________________________________________________________________________________

fricas [F(-2)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Exception raised: TypeError} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*cos(d*x+c))^(1/2)/x,x, algorithm="fricas")

[Out]

Exception raised: TypeError >>  Error detected within library code:   integrate: implementation incomplete (ha
s polynomial part)

________________________________________________________________________________________

giac [C]  time = 0.54, size = 166, normalized size = 1.98 \[ -\frac {\sqrt {2} {\left (\Re \left (\operatorname {Ci}\left (\frac {1}{2} \, d x\right ) \right ) \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right ) \tan \left (\frac {1}{4} \, c\right )^{2} + \Re \left (\operatorname {Ci}\left (-\frac {1}{2} \, d x\right ) \right ) \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right ) \tan \left (\frac {1}{4} \, c\right )^{2} + 2 \, \Im \left (\operatorname {Ci}\left (\frac {1}{2} \, d x\right ) \right ) \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right ) \tan \left (\frac {1}{4} \, c\right ) - 2 \, \Im \left (\operatorname {Ci}\left (-\frac {1}{2} \, d x\right ) \right ) \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right ) \tan \left (\frac {1}{4} \, c\right ) + 4 \, \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right ) \operatorname {Si}\left (\frac {1}{2} \, d x\right ) \tan \left (\frac {1}{4} \, c\right ) - \Re \left (\operatorname {Ci}\left (\frac {1}{2} \, d x\right ) \right ) \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right ) - \Re \left (\operatorname {Ci}\left (-\frac {1}{2} \, d x\right ) \right ) \mathrm {sgn}\left (\cos \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )\right )} \sqrt {a}}{2 \, {\left (\tan \left (\frac {1}{4} \, c\right )^{2} + 1\right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*cos(d*x+c))^(1/2)/x,x, algorithm="giac")

[Out]

-1/2*sqrt(2)*(real_part(cos_integral(1/2*d*x))*sgn(cos(1/2*d*x + 1/2*c))*tan(1/4*c)^2 + real_part(cos_integral
(-1/2*d*x))*sgn(cos(1/2*d*x + 1/2*c))*tan(1/4*c)^2 + 2*imag_part(cos_integral(1/2*d*x))*sgn(cos(1/2*d*x + 1/2*
c))*tan(1/4*c) - 2*imag_part(cos_integral(-1/2*d*x))*sgn(cos(1/2*d*x + 1/2*c))*tan(1/4*c) + 4*sgn(cos(1/2*d*x
+ 1/2*c))*sin_integral(1/2*d*x)*tan(1/4*c) - real_part(cos_integral(1/2*d*x))*sgn(cos(1/2*d*x + 1/2*c)) - real
_part(cos_integral(-1/2*d*x))*sgn(cos(1/2*d*x + 1/2*c)))*sqrt(a)/(tan(1/4*c)^2 + 1)

________________________________________________________________________________________

maple [F]  time = 0.10, size = 0, normalized size = 0.00 \[ \int \frac {\sqrt {a +a \cos \left (d x +c \right )}}{x}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+a*cos(d*x+c))^(1/2)/x,x)

[Out]

int((a+a*cos(d*x+c))^(1/2)/x,x)

________________________________________________________________________________________

maxima [C]  time = 2.24, size = 61, normalized size = 0.73 \[ -\frac {1}{2} \, {\left ({\left (\sqrt {2} E_{1}\left (\frac {1}{2} i \, d x\right ) + \sqrt {2} E_{1}\left (-\frac {1}{2} i \, d x\right )\right )} \cos \left (\frac {1}{2} \, c\right ) - {\left (i \, \sqrt {2} E_{1}\left (\frac {1}{2} i \, d x\right ) - i \, \sqrt {2} E_{1}\left (-\frac {1}{2} i \, d x\right )\right )} \sin \left (\frac {1}{2} \, c\right )\right )} \sqrt {a} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*cos(d*x+c))^(1/2)/x,x, algorithm="maxima")

[Out]

-1/2*((sqrt(2)*exp_integral_e(1, 1/2*I*d*x) + sqrt(2)*exp_integral_e(1, -1/2*I*d*x))*cos(1/2*c) - (I*sqrt(2)*e
xp_integral_e(1, 1/2*I*d*x) - I*sqrt(2)*exp_integral_e(1, -1/2*I*d*x))*sin(1/2*c))*sqrt(a)

________________________________________________________________________________________

mupad [F]  time = 0.00, size = -1, normalized size = -0.01 \[ \int \frac {\sqrt {a+a\,\cos \left (c+d\,x\right )}}{x} \,d x \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a + a*cos(c + d*x))^(1/2)/x,x)

[Out]

int((a + a*cos(c + d*x))^(1/2)/x, x)

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {\sqrt {a \left (\cos {\left (c + d x \right )} + 1\right )}}{x}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+a*cos(d*x+c))**(1/2)/x,x)

[Out]

Integral(sqrt(a*(cos(c + d*x) + 1))/x, x)

________________________________________________________________________________________